<%@ page import="org.apache.ibatis.session.SqlSession" %>
<%@ page import="cn.MyBatisUtil" %>
<%@ page import="cn.StudentDao" %>
<%@ page import="cn.Student" %>
<%@ page import="java.util.List" %><%--
  Created by IntelliJ IDEA.
  User: oldliu
  Date: 2021-11-20
  Time: 8:09
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>Title</title>
</head>
<body>
<%
    out.print(request.getParameter("userName")+"新生注册成功了");
%>
<table border="1" cellpadding="0" cellspacing="0">
    <tr>
        <th>学号</th><th>姓名</th><th>手机号</th><th>入学时间</th>
    </tr>
<%
    SqlSession s= MyBatisUtil.get();
    StudentDao mapper = s.getMapper(StudentDao.class);

    List<Student> list = mapper.search(1, 10, "李", "5", "3", start, end);
    MyBatisUtil.close(s);
    for(Student stu:list){
%>
    <tr>
        <td><%=stu.getStuno()%></td>
        <td><%=stu.getSname()%></td>
        <td><%=stu.getTelephone()%></td>
        <td><%=stu.getEnterdate()%></td>

    </tr>
<%}%>
</table>
</body>
</html>
